<template>
  <div class="sortBox" style="position: relative;">
  <van-sidebar v-model="activeKey" class="appSort">
  <van-sidebar-item v-for="(itemss, index) in titles" :key="index" :title="itemss" />
</van-sidebar>
<div class="sortList">
  <a href="/listPage">
  <div class="boxbox" v-for="(item,idx) in sortList" :key="idx" v-show="activeKey==idx">
    <div v-for="(ite , i) in item" :key="i" class="listItem">
      <img :src="ite.img" alt="">
      <p>{{ite.title}}</p>
    </div>
  </div>
  </a>
</div>
  </div>
</template>
<script>
import sortList from "@/db/sort_fenlei.json";
export default {
  data() {
    return {
      sortList,
      // active: 0,
      activeKey:0,
      titles: [
        { text: "美容彩妆" },
        { text: "奶粉/纸尿裤" },
        { text: "母婴专区" },
        { text: "营养保健" },
        { text: "数码家电" },
        { text: "个人选护" },
        { text: "轻奢" },
        { text: "服饰鞋靴" },
        { text: "运动户外" },
        { text: "手表配饰" },
        { text: "家居生活" },
        { text: "环球美食" },
        { text: "全球工厂店" },
        { text: "分组 2" }
      ]
    };
  },

  components: {},

  methods: {
    
  }
};
</script>

<style scoped>
@import "~@/assets/css/sort.css";
</style>